import java.util.Stack;

/**
 * a wrapper for a stack
 * @author BaoTam
 *
 */
public class MyStack implements Structure {

	Stack<Path> stack;
	
	/**
	 * instantiate an empty stack
	 */
	public MyStack() {
		stack = new Stack<Path>();
	}
	
	/**
	 * @param p, the path to be pushed on the stack
	 */
	public void add(Path p) {
		stack.push(p);
	}

	/**
	 * @return the path that has been popped from the stack
	 */
	public Path remove() {
		return stack.pop();
	}

	/**
	 * @return true if the stack is empty, false otherwise
	 */
	public boolean isEmpty() {
		return stack.isEmpty();
	}
}
